package com.rainy.sso.common.service;

import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Set;
import javax.annotation.Resource;
import com.rainy.sso.common.dao.RoleDao;
import com.rainy.sso.client.entity.Role;
import com.rainy.sso.client.service.RoleService;

/**
* @author liuqin on 2017-12-21 14:26:10
*/
@Service("roleService")
public class RoleServiceImpl implements RoleService {

	@Resource
	private RoleDao roleDao;

    @Override
    public List<Role> list(Long offset, Long limit){
		return roleDao.list(offset,limit);
	}

    @Override
    public Long count(Long offset,Long limit){
        return roleDao.count(offset,limit);
	}

    @Override
    public Role getRoleById(Long id){
        return roleDao.getRoleById(id);
	}
	
	@Override
	public void save(Role role){
		roleDao.save(role);
	}
	
	@Override
	public void update(Role role){
		roleDao.update(role);
	}
	
	@Override
	public void delete(Long id){
		roleDao.delete(id);
	}

	@Override
	public Set<Role> queryRoleByIds(List<Long> ids) {
		return roleDao.queryRoleByIds(ids);
	}
}
